﻿@model NCP.Recruiting.WebApp.Models.ResumePreviewModel
@{
    ViewBag.Title = "Priview";
}

<script type="text/javascript">
    $(function () {
        $('#btnShowContact').bind('click', function () {
            if (confirm('您是否确定要消费点数来查看该人员的联系方式？')) {
                return true;
            }
            return false;
        });

        @if (ViewBag.SetShowContactFlagError != null)
        {
            @:alert('@(ViewBag.SetShowContactFlagError)');
        }
    });

</script>

<div style="float: right; padding-top: 30px; padding-right: 150px">
    @if (Model.PreviousId.HasValue)
    {
        @Html.ActionLink("上一张", "Priview", new { id = Model.PreviousId, isShowSelected = true })
    }
    @if (Model.NextId.HasValue)
    {
        @Html.ActionLink("下一张", "Priview", new { id = Model.NextId, isShowSelected = true })
    }

    @if (!Model.ResumeViewModel.IsShowContact)
    {
        using(Html.BeginForm())
        {
            <input type="hidden" name="resumeId" value="@(Model.ResumeViewModel.ResumeId)" />
            <input type="hidden" name="isShowSelected" value="@(Model.PreviousId.HasValue || Model.NextId.HasValue)" />
            <input id="btnShowContact" type="submit" name="ShowContact" value="查看联系方式" />
        }
    }
    else
    {
        <div>
            已将简历保存在招聘管理的自选简历中
        </div>
    }
</div>
@Html.Partial("~/Views/Candidate/_ReumeList.cshtml", Model.ResumeViewModel)